evaluated exactly once during execution (it has an effect similar to the
static keyword), do demonstrate this behaviour run the code
for ($i = 0; $i < 10; ++$i) require("file.txt");
in a directory that has a file called 'file.txt' and then change require()
to require_once();
# gallery
$text = Parser::extractTags('gallery', $text, $gallery_content, $uniq_prefix);
foreach( $gallery_content as $marker => $content ) {
- require_once( 'ImageGallery.php' ); // FIXME require in a foreach ?
+ require_once( 'ImageGallery.php' );
if ( $render ) {
$gallery_content[$marker] = Parser::renderImageGallery( $content );
} else {